package com.xqzgj.system.service.impl;

import java.util.List;
import java.util.Map;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.xqzgj.system.mapper.StockStatisticsMapper;
import com.xqzgj.system.domain.StockStatistics;
import com.xqzgj.system.service.IStockStatisticsService;

/**
 * 库存统计Service业务层处理
 * 
 * @author xqzgj
 * @date 2024-03-25
 */
@Service
public class StockStatisticsServiceImpl implements IStockStatisticsService {
    @Autowired
    private StockStatisticsMapper stockStatisticsMapper;

    /**
     * 查询库存统计列表
     * 
     * @param stockStatistics 库存统计
     * @return 库存统计
     */
    @Override
    public List<StockStatistics> selectStockStatisticsList(StockStatistics stockStatistics) {
        return stockStatisticsMapper.selectStockStatisticsList(stockStatistics);
    }

    /**
     * 查询库存统计
     * 
     * @param id 库存统计主键
     * @return 库存统计
     */
    @Override
    public StockStatistics selectStockStatisticsById(Long id) {
        return stockStatisticsMapper.selectStockStatisticsById(id);
    }

    /**
     * 新增库存统计
     * 
     * @param stockStatistics 库存统计
     * @return 结果
     */
    @Override
    public int insertStockStatistics(StockStatistics stockStatistics) {
        return stockStatisticsMapper.insertStockStatistics(stockStatistics);
    }

    /**
     * 修改库存统计
     * 
     * @param stockStatistics 库存统计
     * @return 结果
     */
    @Override
    public int updateStockStatistics(StockStatistics stockStatistics) {
        return stockStatisticsMapper.updateStockStatistics(stockStatistics);
    }

    /**
     * 批量删除库存统计
     * 
     * @param ids 需要删除的库存统计主键
     * @return 结果
     */
    @Override
    public int deleteStockStatisticsByIds(Long[] ids) {
        return stockStatisticsMapper.deleteStockStatisticsByIds(ids);
    }

    /**
     * 获取库存统计图表数据
     * 
     * @param stockStatistics 库存统计信息
     * @return 图表数据
     */
    @Override
    public Object getStockStatisticsChartData(StockStatistics stockStatistics) {
        return stockStatisticsMapper.selectStockStatisticsChartData(stockStatistics);
    }

    /**
     * 获取库存统计报表数据
     * 
     * @param stockStatistics 库存统计信息
     * @return 报表数据
     */
    @Override
    public Object getStockStatisticsReportData(StockStatistics stockStatistics) {
        return stockStatisticsMapper.selectStockStatisticsReportData(stockStatistics);
    }
}